<%@ page language="java" contentType="text/html; charset=UTF-8"
pageEncoding="UTF-8"%>
<%@taglib prefix="mvc" uri="http://www.springframework.org/tags/form" %>
<%@taglib prefix="fmt" uri="http://www.springframework.org/tags" %>
<%
String path = request.getContextPath();
String basePath = request.getScheme()+"://"+request.getServerName()+":"+request.getServerPort()+path+"/";
%>
<!DOCTYPE html>
<html>
<head lang="en">
    <meta charset="UTF-8">
    <title>办结工作</title>
    <meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1">
    <link rel="stylesheet" type="text/css" href="/css/main/theme3/fontawesome5.min.css"/>
    <link rel="stylesheet" type="text/css" href="../../css/news/center.css"/>
    <link rel="stylesheet" type="text/css" href="../../lib/laydate.css"/>
    <link rel="stylesheet" type="text/css" href="../../lib/pagination/style/pagination.css"/>
    <link rel="stylesheet" type="text/css" href="../../css/base.css" />
    <link rel="stylesheet" type="text/css" href="/css/base/base.css?20201106.1" />
    <link rel="stylesheet" type="text/css" href="../../css/news/new_news.css"/>
    <link rel="stylesheet" type="text/css" href="../../css/news/management_query.css" />
	<link rel="stylesheet" type="text/css" href="/css/global.css"/>
    <script type="text/javascript" src="../../js/news/jquery-1.9.1.js"></script>
    <script type="text/javascript" src="/js/base/tablePage.js"></script>
    <script src="../../js/news/page.js"></script>
    <script src="../../lib/laydate/laydate.js"></script>
    <script src="../../js/base/base.js" type="text/javascript" charset="utf-8"></script>
    <script src="../../lib/pagination/js/jquery.pagination.min.js" type="text/javascript" charset="utf-8"></script>
    <!-- word文本编辑器 -->
    <script src="../../lib/ueditor/ueditor.config.js" type="text/javascript" charset="utf-8"></script>
    <script src="../../lib/ueditor/ueditor.all.js" type="text/javascript" charset="utf-8"></script>
    <script src="../../js/news/page.js"></script>
    <script src="../../lib/pagination/js/jquery.pagination.min.js" type="text/javascript" charset="utf-8"></script>
    <script src="../../lib/layer/layer.js?20201106"></script>
    <script src="../../js/jquery/jquery.cookie.js"></script>
    <style type="text/css">
	.index_head li span{
        border: 1px #2f8ae3 solid;
        border-radius: 6px;
    }
    .index_head li span:hover {
        background-color: #2f8ae3;
        color: #fff!important;
    }
	#waitwork:hover::before{
   
    color: #fff!important;;
    
}
        span.host-span {
            padding-left: 12px;
        }
        span.host-span{color: #1772c0;}
        .daochu{color: #1772c0;}
        .shanchu{color:#e01919;}
        .operation_text_left {
            padding-left: 20px;
        }

        .button-operation {
            float: left;
            padding-top: 25px;
            padding-bottom: 10px;
            margin-right: 12px;
        }

        .navigation .right {
            float: right;
            margin-top: -141px;
        }
        .zhungtai{
            position:relative;
            left:5px;
        }
        .btn-success {
            border: 1px solid #359947;
            color: #ffffff;
            background-color: #35aa47;
            background-image: -moz-linear-gradient(top, #35aa47, #35aa47);
            background-image: -webkit-gradient(linear, 0 0, 0 100%, from(#35aa47), to(#35aa47));
            background-image: -webkit-linear-gradient(top, #35aa47, #35aa47);
            background-image: -o-linear-gradient(top, #35aa47, #35aa47);
            background-image: linear-gradient(to bottom, #35aa47, #35aa47);
            background-repeat: repeat-x;
            filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#ff35aa47', endColorstr='#ff35aa47', GradientType=0);
            filter: progid:DXImageTransform.Microsoft.gradient(enabled = false);
            width: 100px;
            height: 35px;
        }
        .btn-danger {
            border: 1px solid #c6322a;
            color: #ffffff;
            background-color: #d84a38;
            background-image: -moz-linear-gradient(top, #dd4b39, #d14836);
            background-image: -webkit-gradient(linear, 0 0, 0 100%, from(#dd4b39), to(#d14836));
            background-image: -webkit-linear-gradient(top, #dd4b39, #d14836);
            background-image: -o-linear-gradient(top, #dd4b39, #d14836);
            background-image: linear-gradient(to bottom, #dd4b39, #d14836);
            background-repeat: repeat-x;
            filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#ffdd4b39', endColorstr='#ffd14836', GradientType=0);
            filter: progid:DXImageTransform.Microsoft.gradient(enabled = false);
            width: 100px;
            height: 35px;
        }
        form {
            margin: 0 0 20px;
        }
        .btn-info {
            border: 1px solid #46b8da;
            color: #ffffff;
            background-color: #5bc0de;
            cursor: pointer;
            background-image: -moz-linear-gradient(top, #5bc0de, #5bc0de);
            background-image: -webkit-gradient(linear, 0 0, 0 100%, from(#5bc0de), to(#5bc0de));
            background-image: -webkit-linear-gradient(top, #5bc0de, #5bc0de);
            background-image: -o-linear-gradient(top, #5bc0de, #5bc0de);
            background-image: linear-gradient(to bottom, #5bc0de, #5bc0de);
            background-repeat: repeat-x;
            filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#ff5bc0de',endColorstr='#ff5bc0de',GradientType=0);
            filter: progid:DXImageTransform.Microsoft.gradient(enabled = false);
            width: 70px;
            height: 28px;
            border-radius: 6px;
        }
        .step1_title {
            width: 6%;
            display: inline-block;
            float: left;
            margin-top: 28px;
        }
        .navigation {
            heihgt: 70px;
            /* display: inline-block; */
            /* float: left; */
            width:100%;
        }
        /*.navigation .left .news {
            !* font-size: 14px; *!
            margin-left: 5px;
            font-family: Microsoft yahei,Helvetica Neue,Helvetica,PingFang SC,Tahoma,Arial,sans-serif;
            margin-top: -3px;
            margin-right: 40px;
            font-size: 22px;
            color: #494d59;
            margin-top: 5px;
        }*/

        .navigation .left .news {
            font-size: 14px;
            margin-left: 5px;
            font-family: Microsoft yahei,Helvetica Neue,Helvetica,PingFang SC,Tahoma,Arial,sans-serif;
            margin-top: -3px;
            margin-right: 80px;
            font-size: 16px;
            color: #494d59;
        }

        /*@media screen and (max-width: 1366px) {
            .navigation .left .news {
                font-size: 14px;
                margin-left: 5px;
                font-family: Microsoft yahei,Helvetica Neue,Helvetica,PingFang SC,Tahoma,Arial,sans-serif;
                margin-top: -3px;
                margin-right: 20px;
                font-size: 17pt;
                color: #494d59;
            }
        }*/

        .navigation .left img {
            float: left;
            margin-top: 30px;
            margin-right: 5px;
            width: 25px;
            height: 24px;
        }
        .ui-state-default, .ui-widget-content .ui-state-default, .ui-widget-header .ui-state-default {
            background-color: #f5f5f4;
            background-image: none;
        }
        .ui-state-default, .ui-widget-content .ui-state-default, .ui-widget-header .ui-state-default th {
            border-bottom: 0px;
        }

        .ui-state-default, .ui-widget-content .ui-state-default, .ui-widget-header .ui-state-default {
            border: 1px solid #d3d3d3;
            background: #f5f5f5 url(images/fhbg.gif) 50% 50% repeat-x;
            font-weight: normal;
            color: #555555;
        }
        .ui-jqgrid .ui-jqgrid-hdiv {
            position: relative;
            margin: 0em;
            padding: 0em;
            overflow-x: hidden;
            border-left: 0px none !important;
            border-top: 0px none !important;
            border-right: 0px none !important;
        }
        .ui-jqgrid .ui-jqgrid-view, .ui-jqgrid .ui-jqgrid-pager {
            font-family: inherit;
        }
        .ui-jqgrid .ui-jqgrid-view, .ui-jqgrid .ui-jqgrid-pager {
            background-color: #fff;
            font-family: Microsoft YaHei,Simsun,Verdana,Arial,sans-serif;
            font-size: 9pt;
        }
        #gbox_gridTable {
            border: 1px solid #d3d3d3;
            -moz-border-radius: 2px,2px,0px,0px;
            -webkit-border-radius: 2px, 2px, 0px, 0px;
            border-radius: 4px 4px 0px 0px;
        }
        .ui-jqgrid {
            border-left: 1px solid #d3d3d3;
            border-right: 1px solid #d3d3d3;
        }

        .ui-jqgrid {
            position: relative;
        }
        .head {
            border-bottom: 1px solid #9E9E9E;
            padding-bottom: 3px;
            height: 47px;
            background-color:#e4eff8;
        }

		.hui_tubiao::before {
		
		    content: "\f01e" !important;
			line-height: 2 !important;
			font-size: 12px !important;
		}
    </style>
    <style type="text/css">
        .cbox{
            display: none;
        }
        .search_area {
            padding: 8px 0px;
            margin: 0 auto;
            text-align: center;
            margin-top: 0px;
            background-color: #f5f5f5;
            border-bottom: 1px solid #dddddd;
        }
        .search_area {
            padding: 8px 0px;
            margin: 0 auto;
            text-align: center;
            margin-top: 0px;
            background-color: #f5f5f5;
            border-bottom: 1px solid #dddddd;
        }
        .form-search .input-append{
            margin-bottom: 0;
        }
        .form-search .input-append{
            display: inline-block;
            margin-bottom: 0;
            vertical-align: middle;
        }
        .form-search .input-append .search-query {
            -webkit-border-radius: 14px 0 0 14px;
            -moz-border-radius: 14px 0 0 14px;
            border-radius: 14px 0 0 14px;
        }
        .search_normal .input-append .btn {
            vertical-align: middle;
            /* background-color: #f5f5f4; */
        }
        input.search-query {
            padding-right: 14px;
            padding-right: 4px \9;
            padding-left: 14px;
            padding-left: 4px \9;
            margin-bottom: 0;
        }
        .btn-primary {
            border: 1px solid #3079ed;
            color: #ffffff;
            background-color: #4b8cf7;
            background-image: -moz-linear-gradient(top, #4d90fe, #4787ed);
            background-image: -webkit-gradient(linear, 0 0, 0 100%, from(#4d90fe), to(#4787ed));
            background-image: -webkit-linear-gradient(top, #4d90fe, #4787ed);
            background-image: -o-linear-gradient(top, #4d90fe, #4787ed);
            background-image: linear-gradient(to bottom, #4d90fe, #4787ed);
            background-repeat: repeat-x;
            filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#ff4d90fe', endColorstr='#ff4787ed', GradientType=0);
            filter: progid:DXImageTransform.Microsoft.gradient(enabled = false);
        }
        input.span4, textarea.span4,.uneditable-input.span4 {
            width: 286px;
        }
        .span4 search-query{
            width:316px;
            height:30px;
        }
        /*.daochuwork{width:110px !important;}*/
        
       
        .btn_checked {
            position: relative;
            padding: 4px 12px;
            margin: 0;
            color: #333;
            text-shadow: 0 1px 0 #fff;
            white-space: nowrap;
            font-family: Simsun, Arial, sans-serif;
            font-weight: bold;
            font-size: 13px;
            text-align: center;
            vertical-align: middle;
            -webkit-background-clip: padding;
            -moz-background-clip: padding;
            cursor: default;
            background-color: #f3f3f3;
            background-image: -moz-linear-gradient(top, #f5f5f5, #f1f1f1);
            background-image: -webkit-gradient(linear, 0 0, 0 100%, from(#f5f5f5), to(#f1f1f1));
            background-image: -webkit-linear-gradient(top, #f5f5f5, #f1f1f1);
            background-image: -o-linear-gradient(top, #f5f5f5, #f1f1f1);
            background-image: linear-gradient(to bottom, #f5f5f5, #f1f1f1);
            background-repeat: repeat-x;
            filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#fff5f5f5', endColorstr='#fff1f1f1', GradientType=0);
            border: 1px solid #dcdcdc;
            -webkit-border-radius: 2px;
            -moz-border-radius: 2px;
            border-radius: 2px;
            -webkit-box-shadow: none;
            -moz-box-shadow: none;
            box-shadow: none;
        }
        #table1 {
            border-collapse: collapse;
            border-spacing: 0;
            margin-top: 6px;
            width: 700px;
            float: left;
        }
        .inp {
            width: 200px;
            height: 30px;
            border-radius: 6px;
        }
        .inp, .search {
            float: left;
        }
        .navigation .right {
            float: right;
            margin-top: 0px;
        }
        .subsearch {
            width: 65px;
            height: 28px;
        //padding-left: 10px;
            line-height: 30px;
            margin-top:0px;
            margin-right: 1px;
            text-align: center;
        //background-image: url(../../img/center_q.png);
        //background-repeat: no-repeat;
        //background-size: 100% 100%;
            background-color: #2b7fe0;
            border: 1px solid #2b7fe0;
            border-radius: 6px;
            color: #fff ;
            cursor: pointer;
            font-family: Microsoft yahei,Helvetica Neue,Helvetica,PingFang SC,Tahoma,Arial,sans-serif;
        }
        #pageTbody tr{
            cursor: pointer;
            background-color:#fff !important;
        }
        .button-operation {
            float: right;
            padding-top: 18px;
            padding-bottom: 10px;
            /*margin-right: 12px;*/
        }
        /*.btn-success {
            border: 1px solid #359947;
            color: #ffffff;
            background-color: #35aa47;
            background-image: -moz-linear-gradient(top, #35aa47, #35aa47);
            background-image: -webkit-gradient(linear, 0 0, 0 100%, from(#35aa47), to(#35aa47));
            background-image: -webkit-linear-gradient(top, #35aa47, #35aa47);
            background-image: -o-linear-gradient(top, #35aa47, #35aa47);
            background-image: linear-gradient(to bottom, #35aa47, #35aa47);
            background-repeat: repeat-x;
            filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#ff35aa47', endColorstr='#ff35aa47', GradientType=0);
            filter: progid:DXImageTransform.Microsoft.gradient(enabled = false);
            height: 30px;
            width: 85px;
        }*/
        .btn-success {
            border: 1px solid #2b7edf;
            color: #ffffff;
            background-color: #2b7edf;
            background-image: -moz-linear-gradient(top, #2b7edf, #2b7edf);
            background-image: -webkit-gradient(linear, 0 0, 0 100%, from(#2b7edf), to(#2b7edf));
            background-image: -webkit-linear-gradient(top, #2b7edf, #2b7edf);
            background-image: -o-linear-gradient(top, #2b7edf, #2b7edf);
            background-image: linear-gradient(to bottom, #2b7edf, #2b7edf);
            background-repeat: repeat-x;
            filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#2b7edf', endColorstr='#2b7edf', GradientType=0);
            filter: progid:DXImageTransform.Microsoft.gradient(enabled = false);
            height: 28px;
            width: 70px;
            cursor: pointer;
            border-radius: 6px;
            font-size: 10pt;
        }
        .btn-success:hover{
            border: 1px solid #3b8eef;
            color: #ffffff;
            background-color: #3b8eef;
            background-image: -moz-linear-gradient(top, #3b8eef, #3b8eef);
            background-image: -webkit-gradient(linear, 0 0, 0 100%, from(#3b8eef), to(#3b8eef));
            background-image: -webkit-linear-gradient(top, #3b8eef, #3b8eef);
            background-image: -o-linear-gradient(top, #3b8eef, #3b8eef);
            background-image: linear-gradient(to bottom, #3b8eef, #3b8eef);
            background-repeat: repeat-x;
            filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#3b8eef', endColorstr='#3b8eef', GradientType=0);
            filter: progid:DXImageTransform.Microsoft.gradient(enabled = false);
            /*height: 30px;*/
            /*width: 82px;*/
        }
        /*.btn-info {
            border: 1px solid #00a0e9;
            color: #ffffff;
            background-color: #00a0e9;
            cursor: pointer;
            background-image: -moz-linear-gradient(top, #00a0e9, #00a0e9);
            background-image: -webkit-gradient(linear, 0 0, 0 100%, from(#00a0e9), to(#00a0e9));
            background-image: -webkit-linear-gradient(top, #00a0e9, #00a0e9);
            background-image: -o-linear-gradient(top, #00a0e9, #00a0e9);
            background-image: linear-gradient(to bottom, #00a0e9, #00a0e9);
            background-repeat: repeat-x;
            filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#ff5bc0de', endColorstr='#ff5bc0de', GradientType=0);
            filter: progid:DXImageTransform.Microsoft.gradient(enabled = false);
            height: 29px;
            width: 82px;
        }*/
        .btn-info {
            border: 1px solid #2b7edf;
            color: #ffffff;
            background-color: #2b7edf;
            cursor: pointer;
            background-image: -moz-linear-gradient(top, #2b7edf, #2b7edf);
            background-image: -webkit-gradient(linear, 0 0, 0 100%, from(#2b7edf), to(#2b7edf));
            background-image: -webkit-linear-gradient(top, #2b7edf, #2b7edf);
            background-image: -o-linear-gradient(top, #2b7edf, #2b7edf);
            background-image: linear-gradient(to bottom, #2b7edf, #2b7edf);
            background-repeat: repeat-x;
            filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#2b7edf', endColorstr='#2b7edf', GradientType=0);
            filter: progid:DXImageTransform.Microsoft.gradient(enabled = false);
            /*height: 30px;*/
            /*width: 82px;*/
            height: 28px;
            width: 70px;
            border-radius: 6px;
            font-size: 10pt;
        }
        .btn-info:hover{
            border: 1px solid #3b8eef;
            color: #ffffff;
            background-color: #3b8eef;
            cursor: pointer;
            background-image: -moz-linear-gradient(top, #3b8eef, #3b8eef);
            background-image: -webkit-gradient(linear, 0 0, 0 100%, from(#3b8eef), to(#3b8eef));
            background-image: -webkit-linear-gradient(top, #3b8eef, #3b8eef);
            background-image: -o-linear-gradient(top, #3b8eef, #3b8eef);
            background-image: linear-gradient(to bottom, #3b8eef, #3b8eef);
            background-repeat: repeat-x;
            filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#3b8eef', endColorstr='#3b8eef', GradientType=0);
            filter: progid:DXImageTransform.Microsoft.gradient(enabled = false);
            /*height: 30px;*/
            /*width: 82px;*/
        }
        .head .one {
            background-color: #2F8AE3;
            font-size: 14px;
            color: #ffffff;
            border-radius: 6px;
        }
        .font-green {
            color: green;
        }
        tr td{
            font-size:13px;
        }
        .step{
            margin-left: 15px;
        }
        .wenhao:hover{
            cursor: pointer;
            color: #2f8ae3;
        }
        .bjtitle:hover{
            cursor: pointer;
            color: #2f8ae3;
        }
        .alerthtml:hover{cursor: pointer;color: #2f8ae3;}
        .hidden{display: none;}
        .flowtype{  cursor: pointer;  }
        .flowtype:hover{  cursor: pointer; color: #1772c0 }
        .flowtitle{  cursor: pointer;  }
        .flowtitle:hover{  cursor: pointer; color: #1772c0 }
        table{
            table-layout: fixed;
        }

        table tr th {
            text-align: left;
            padding: 5px 4px!important;
        }
       
        .banjietr td span{
            display: inline-block;
            width: 100%;
        }
        .navigation .left{
            /*margin-left: 17px;*/
            /*margin-left: 30px;*/
        }
        .editAndDelete1{
            color: #e01919;
        }
        .head{
            position: fixed;
            top: 0;
            left: 0;
            background: #fff;
        }

        .pagediv .page-top-outer-layer:before {
            content: '';
            display: block;
            width: 100%;
            height: 5px;
            background-color: #2a7ddc;
            border-radius: 3px;
        }

        .pagediv .page-top-inner-layer {
            height: 42px;
        }
        /*.head .headli3{*/
        /*width: 64px;*/
        /*}*/

        .pagediv .page-top-inner-layer table tr {
            border-color: #e8f4fc;
        }

        .pagediv .page-bottom-outer-layer table td >span {
            color: #000;
        }

        .pagediv .page-bottom-inner-layer table tr {
            border: none;
        }
        #pageTbody tr:hover {
            background-color: #e8f4fc !important;
        }
        .navigation .left img{
            margin-top: 22px;
            width: 10px;
            height: 6px;
        }

        @media screen and (max-width: 1159px) {
            .navigation .left .news {
                margin-right: 30px;
            }
        }
        #flow_search_value_bj{
            border:1px solid #ccc;
			
border: 1px solid #cccccc;
-webkit-box-shadow: inset 0 1px 1px rgba(0, 0, 0, 0.075);
-moz-box-shadow: inset 0 1px 1px rgba(0, 0, 0, 0.075);
box-shadow: inset 0 1px 1px rgba(0, 0, 0, 0.075);
-webkit-transition: border linear .2s, box-shadow linear .2s;
-moz-transition: border linear .2s, box-shadow linear .2s;
-o-transition: border linear .2s, box-shadow linear .2s;
vertical-align: initial;
position: relative;
top: -0.5px;
height: 30.5px !important;
        }

        .sel{
            width:149px;
            max-height:250px;
            position: absolute;
            top:50px;
            left:62px;
            overflow: auto;
            background: #fff;
            border:1px solid #e2e3e3;
            display: none;
            cursor: pointer;
			border-radius:6px;
        }
        .sel li{
            line-height: 24px;
            color: #000;
        }
        #list{
            width: 30px;
            height: 20px;
            background: #fff;
            border: none;

            vertical-align: middle;
            position: absolute;
            right: 5px;
            top: 22px;
            border-radius: 0px 3px 3px 0px;
            border-left: none;
        }
        #list img{
            margin-top: 0px;
            margin-left: 14px;
        }
        .canchoose:hover{
            background: #2b7edf;
            color: #fff;
        }
        input[name="flowName"]{
            width:150px;
            height:30px;
            border-radius: 6px;
            margin-top: 0px;
            border: 1px solid #ccc;
			background-color: #ffffff;
border: 1px solid #cccccc;
-webkit-box-shadow: inset 0 1px 1px rgba(0, 0, 0, 0.075);
-moz-box-shadow: inset 0 1px 1px rgba(0, 0, 0, 0.075);
box-shadow: inset 0 1px 1px rgba(0, 0, 0, 0.075);
-webkit-transition: border linear .2s, box-shadow linear .2s;
-moz-transition: border linear .2s, box-shadow linear .2s;
-o-transition: border linear .2s, box-shadow linear .2s;
vertical-align:initial;
position: relative;
top: 1.5px;
height: 30.5px !important;
        }
        .headli1_2_icon{
            margin-top: -2px!important;
            width:13px;
            display:none
        }
        .pagediv .page-bottom-outer-layer table td:nth-child(3){
            text-overflow:clip!important;
            white-space: normal!important;
        }
        .pagediv .page-bottom-outer-layer table td{
            font-size: 10pt;
            white-space: normal;
        }
        .pagediv .page-top-inner-layer table th{
            font-size: 14px;
            line-height: 30px;
            background-color: #e8f4fc;
        }
        .pagediv .page-top-inner-layer table{
            box-shadow: 0 0px 0px rgba(0, 0, 0, 0.2);
        }
        .navigation .left{
            line-height:65px
        }
        .page-bottom-inner-layer{
            scrollbar-width: none}
        .page-bottom-inner-layer::-webkit-scrollbar{
            width: 0px
        }
        .pagediv{
            scrollbar-width: none}
        .pagediv::-webkit-scrollbar{
            width: 0px
        }

        .btn-success img,
        button.daochuwork img,
        .btn-delete img,
        .btn-info img,
        #endWork img,
        #waitwork img,
        .navigation .left img {
            display: none;
        }

        .btn-success:before,
        button.daochuwork:before,
        .btn-delete:before,
        .btn-info:before,
        #bjgz_search:before,
        #endWork:before,
        #waitwork:before,
        .navigation .left:before {
            font-family: "Font Awesome 5 Pro";
            -webkit-font-smoothing: antialiased;
            -moz-osx-font-smoothing: grayscale;
            display: inline-block;
            font-style: normal;
            font-variant: normal;
            font-weight: 300;
            line-height: 1;
        }

        .btn-success:before {
            content: '\f067';
        }
        button.daochuwork:before {
            content: '\f093';
        }
        .btn-delete:before {
            content: '\f00d';
        }
        .btn-info:before {
            content: '\f01e';
        }

        #bjgz_search:before {
            content: '\f002';
            margin-right: 4px;
        }

        #waitwork:before {
            content: '\f017';
            color: #2b7fe0;
            margin-right: 1px;
        }


        #endWork:before {
            content: '\f058';
            color: #fff;
            font-weight: 300;
            margin-right: 2px;
        }
        /*代办工作列表操作按钮模板 复制到需要的页面文件中 开始*/
        .editAndDelete0 > span img,
        .editAndDelete1 > span img,
        .editAndDelete2 > span img,
        .editAndDelete3 > span img,
        .editAndDelete4 > span img {
            display: none;
        }

        .editAndDelete0 > span:before,
        .editAndDelete1 > span:before,
        .editAndDelete2 > span:before,
        .editAndDelete3 > span:before,
        .editAndDelete4 > span:before {
            font-family: "Font Awesome 5 Pro";
            -webkit-font-smoothing: antialiased;
            -moz-osx-font-smoothing: grayscale;
            display: inline-block;
            font-style: normal;
            font-variant: normal;
            font-weight: 300;
            line-height: 1;
            color: #fff;
            margin-right: 3px;
        }
        .editAndDelete0,
        .editAndDelete1,
        .editAndDelete2,
        .editAndDelete3,
        .editAndDelete4 {
            margin-right: 10px;
            margin-bottom: 5px;
            margin-top: 5px;
        }
        .editAndDelete0 > span,
        .editAndDelete1 > span,
        .editAndDelete2 > span,
        .editAndDelete3 > span,
        .editAndDelete4 > span {
            font-size: 12px;
            background-color: #2b7edf !important;
            height: 25px !important;
        }
        /*只要修改content值*/
        /*查看：f865
          删除或者回收等：f2ed
          传阅：f5da
          转交：f4c6
          委托：f4c4
          催办：f7e4
          结束：f895
        */
        .editAndDelete0 > span:before {
            content: "\f865";
        }
        .editAndDelete1 > span:before {
            content: "\f2ed";
        }
        .editAndDelete2 > span:before {
            content: "\f5da";
        }
        .editAndDelete3 > span:before {
            content: "\f865";
        }
        .editAndDelete4 > span:before {
            content: "\f865";
        }
        /*代办工作列表操作按钮模板 复制到需要的页面文件中 结束*/
        .head .index_head li {
            /*width: 195px;*/
        }
        .head .index_head li #waitwork {
            /*width: 112px;*/
			color: #2b7edf;
            
        }
        .head .index_head li #endWork:hover {
            background-color: #4b95ed !important;
        }
        .head .index_head li span {
            margin-top: 8px;
            margin-left: 25px;
            padding: 7px 14px;
            padding-left:14px;
            font-size: 10pt;
        }
    </style>
    <link rel="stylesheet" type="text/css" href="/css/commonTheme/${sessionScope.InterfaceModel}/commonTheme.css"/>

</head>
<body>
<!--head开始-->
<div class="head w clearfix" >
    <ul class="index_head">
        <li data-num="0"><span class="headli1_1" id="waitwork"><img class="headli1_2_icon" src="../../img/workflow/work/waitwork.png" alt="" style="margin-top: 0">&nbsp;<fmt:message code="workflow.th.wait" /></span><img class="headli1_2" src="../../img/twoth.png" alt="">
        </li>

        <li data-num="1"><span class="headli2_1 endWork one"  id="endWork"><img class="headli1_2_icon" src="../../img/workflow/work/endworkchoose.png" alt="" style="margin-top: 0">&nbsp;已办工作</span>
        </li>


    </ul>
</div>
<div class="body" style="width: 100%;margin-top: 44px">
    <div class="bx">
        <div class="navigation  clearfix" style="width: 97%; display: block; margin: auto;">
            <div class="left">

                <div class="nameBox" style="position: relative;margin-right: 10px;">
                    <span class="fl" style="margin-top: 0px;line-height: 65px; margin-right: 22px; font-size: 10pt;"><fmt:message code="workflow.th.name1"/>：</span>
                    <input type="text" name="flowName" placeholder="流程名称" dataType="" style="width: 150px;padding-left: 5px">
                    <button id="list"><img src="../../img/workflow/work/workListXiala.png" style="margin-top: 0px;margin-left: 14px;width: 15px;height: 12px;display:inline" alt="">
					</button>
                    <ul class="sel"></ul>
                </div>
                <%--<select name="dispatchType" style="float: left;margin-top: 25px;margin-right: 24px; padding-left: 10px; outline: none; border-radius: 6px;">--%>
                <%--<option value=""><fmt:message code="hr.th.PleaseSelectFlow"/></option>--%>
                <%--</select>--%>

                <div style="margin-top: 18.5px; display: inline-block; position: relative">
                    <input style="padding-left: 5px; padding-right: 69px;margin-top: 0px;width:220px;" id="flow_search_value_bj" class="inp" type="text" placeholder="输入流水号或标题">
                    <div id="btn_search" class="search" style="position: absolute; right: 0;"><h1 style="cursor:pointer; font-size: 10pt;" class="subsearch" id="bjgz_search">查询</h1></div>
                </div>
            </div>

            <div class="button-operation" style="font-size: 0px;">




                <button type="button" class="g_button_z_2z g_button_z_new btn btn-success" onclick="clicked5();" style="margin-right: 10pt;position: relative;"><span ><fmt:message code="main.newwork" /></span></button>
                <form name="selected_export_form" id="selected_export_form" style="display: none;" method="post" action="data/work_to_export.php?ispirit_export=1">
                    <input type="hidden" name="THE_ID_STR" id="THE_ID_STR" value="">
                    <button type="submit" id="selected_export" class="btn btn-info"><fmt:message code="global.lang.report" /></button>
                </form>
                <button type="button" id="export" class="g_button_f_2z g_button_z_export daochuwork" onclick="clicked1();" style="margin-right: 10pt;"><span ><fmt:message code="workflow.th.Exportwork" /></span></button>
                <button type="button" class="g_button_f_2z g_button_z_reset" id="refresh1" onclick="clicked2();"><span ><fmt:message code="global.lang.refresh" /></span></button>



            </div>
            <script>
                $(function(){
                    var xinJian=$(".btn-success span").text();
                    xinJian=xinJian.substring(0,2);
                    $(".btn-success span").text(xinJian);
                    var daoChu=$("#export span").text();
                    daoChu=daoChu.substring(0,2);
                    $("#export span").text(daoChu);


                })
            </script>

        </div>
        <div id="pagediv">

        </div>
    </div>
</div>
<script type="text/javascript" src="/js/spirit/qwebchannel.js"></script>
<script>
    $(document).keyup(function (e) {//捕获文档对象的按键弹起事件
        if (e.keyCode == 13) {//按键信息对象以参数的形式传递进来了
            //此处编写用户敲回车后的代码
            $('#btn_search h1').click();
        }
    });
    $(function(){
        $('.index_head li').click(function(){
            var datanums = $(this).attr('data-num');
            $(this).find('span').addClass('one').parent().siblings().find('span').removeClass('one');
            if(datanums == 0){
                window.location.href='/workflow/work/workList';
            }else if(datanums == 1){
                window.location.href='/workflow/work/endwork';
            }else if(datanums == 2){
                window.location.href='/workflow/work/allwork';
            }else if (datanums == 3) {
                window.location.href = '/workflow/work/entrustWorkMap';
            }
        })

    })

    //获取待办数量
    var dataNum=""
    function getDataNum() {
        $.ajax({
            url:'../../workflow/work/selectWork?page=1&pageSize=10&useFlag=true',
            type:'get',
            dataType:'json',
            async: false,//同步请求,这里使用ajax必须使用同步方式请求，因为浏览器认为这种打开在ajax后新页面是不安全的
            success:function(res){

                if(res.flag){

                    dataNum=res.totleNum

                }else {
                    dataNum="0"

                }
            },
            error:function () {
                dataNum="error"
            }
        })
    }

    $(function () {
        if(dataNum==""){

            getDataNum()
		}
		if(dataNum>99){
			dataNum="99+";
		}
         $("#waitwork").append('&thinsp;<num style="margin-left: 3px">('+dataNum+')</num>');
        
    })
</script>
<script type="text/javascript">
    var allDept="";
    function getAllDept() {
        $.ajax({
                url:'/department/getAlldept',
                type:'get',
                dataType:'json',
                async: false,//同步请求,这里使用ajax必须使用同步方式请求，因为浏览器认为这种打开在ajax后新页面是不安全的
                success:function(res){
                    if(res.flag==true){
                        allDept = res.obj;

                    }
                }
            }
        )}
    function runWorkListPage() {
        location.reload();
    }
    function clicked5(){
        if( parent.parent.urlnewworkflow != undefined){
            parent.parent.urlnewworkflow()
        }else{
            window.open('/workflow/work/addwork')
        }
    }
    function clicked1(){
        window.location.href ="exportExcel?type=2"
    }
    function clicked2(){
        location.reload();
    }
    function getWorkLevle(num_workLevel){
        var str_workLevel;
        switch(num_workLevel){
            case 0:
                str_workLevel='普通';
                break;
            case 2:
                str_workLevel='特急';
                break;
            case 1:
                str_workLevel='紧急';
                break;
            default:
                str_workLevel='普通';
        }
        return str_workLevel;
    }
    function handleData(data){
        switch(data){
            case "1":
                return '<fmt:message code="lang.th.will" />';
            case "2":
                return '<fmt:message code="lang.th.Process" />';
            case "3":
                return '<fmt:message code="main.th.ToStep" />';
            case "4":
                return '<fmt:message code="lang.th.HaveThrough" />';
            case "5":
                return '<fmt:message code="workflow.th.FreeFlowPresettingSteps" />';
            case "6":
                return '<fmt:message code="workflow.th.HasBeenSuspended" />';
        }
    }
    function js_method(e){
        e.parents('tr').find('.editAndDelete0').click();
    }
    var eventas=null;
    function bzlct(e){
        window.event.cancelBubble = true;
        eventas=e;
        window.open('/flowSetting/processDesignToolTwo?flowId='+e.attr('flowid')+'&rilwId='+e.attr('runid'),'');
    }

    function openthis(e){
        var runid = e.attr('runid');
        var index = e.parents('tr').attr('indexnum');
        if(e.hasClass('active')){
            $('#pageTbody .hide[name='+ runid +']').parents('tr').hide();
            e.attr({
                'title':'点击展开',
                'src':'../../img/mywork/addlogo.png'
            }).removeClass('active').parents('tr').show();
            if(index == 4){
                e.parents('tr').css({
                    'border-bottom':'1px solid #c0c0c0',
                });
            }
        }else{
            $('#pageTbody .hide[name='+ runid +']').parents('tr').show().css({
                'border-top':'none',
                'border-bottom':'none',
            });
            e.addClass('active').attr({
                'title':'点击收起',
                'src':'../../img/mywork/deletelogo.png'
            }).parents('tr').css({
                'border-top':'1px solid #c0c0c0',
            });
            for(var i=0;i<$('#pageTbody .hide[name='+ runid +']').length;i++){
                if(index == 0||index == 2||index == 4){
                    if(index == 4){
                        if(i == $('#pageTbody .hide[name='+ runid +']').length-1){
                            $('#pageTbody .hide[name='+ runid +']').eq(i).parents('tr').css({
                                'border-bottom':'1px solid #c0c0c0',
                            });
                        }
                    }
                    $('#pageTbody .hide[name='+ runid +']').eq(i).parents('tr').css({'background-color': '#F6F7F9'});
                }else{
                    $('#pageTbody .hide[name='+ runid +']').eq(i).parents('tr').css({'background-color': '#FFFFFF'});
                }
            }
            if(index == 0){
                e.parents('tr').css({
                    'border-top':'none',
                });
            }
        }

    }
    window.onresize = function(){
        var screenwidth = document.documentElement.clientWidth;
        if(screenwidth > 1135){
            var nums = screenwidth*0.97;
            var sumwidth = screenwidth*0.97+'px';
        }else{
            var nums = 1100;
            var sumwidth = '1100px';
        }
        var width1 = nums*0.06+'px';
        var width9 = nums*0.01+'px';
        var width2 = nums*0.080+'px';
        var width10 = nums*0.130+'px';
        var width7 = nums*0.080+'px';
        var width11 = nums*0.100+'px';
        var width3 = nums*0.055+'px';
        var width5 = nums*0.096+'px';
        var width8 = nums*0.116+'px';
        pageObj.configuration[0]['width'] = nums * 0.06 + 'px';
        pageObj.configuration[1]['width'] = nums * 0.01 + 'px';
        pageObj.configuration[2]['width'] = nums * 0.080 + 'px';
        pageObj.configuration[3]['width'] = nums * 0.130 + 'px';
        pageObj.configuration[4]['width'] = nums * 0.080 + 'px';
        pageObj.configuration[5]['width'] = nums * 0.100 + 'px';
        pageObj.configuration[6]['width'] = nums * 0.055 + 'px';
        pageObj.configuration[7]['width'] = nums * 0.096 + 'px';
        pageObj.configuration[8]['width'] = nums * 0.116 + 'px';
        $('.page-top-outer-layer').css('width',sumwidth).find('table').css('width',sumwidth);
        for(var i=0;i< $('.page-top-outer-layer').find('th').length;i++){
            $('.page-top-outer-layer').find('th').eq(i).css('width',pageObj.configuration[i]['width']);
        }
        $('.page-bottom-outer-layer').css('width',sumwidth).find('.page-bottom-inner-layer').css('width',sumwidth).find('table').css('width',sumwidth);
        var table = $('.page-bottom-outer-layer .page-bottom-inner-layer table');
        for(var i=0;i<table.find('tr').length;i++){
            for(var j=0;j<table.find('tr').eq(i).find('td').length;j++){
                table.find('tr').eq(i).find('td').eq(j).css('width',pageObj.configuration[j]['width']);
            }
        }
    };

    var screenwidth = document.documentElement.clientWidth;
    if(screenwidth > 1135){
        var nums = screenwidth*0.97;
        var sumwidth = screenwidth*0.97+'px';
    }else{
        var nums = 1100;
        var sumwidth = '1100px';
    }
    var width1 = nums*0.06+'px';
    var width9 = nums*0.01+'px';
    var width2 = nums*0.080+'px';
    var width10 = nums*0.130+'px';
    var width7 = nums*0.080+'px';
    var width11 = nums*0.100+'px';
    var width3 = nums*0.055+'px';
    var width5 = nums*0.096+'px';
    var width8 = nums*0.116+'px';


    var pageObj=$.tablePage('#pagediv',sumwidth,[
        {
            width:width1,
            title:'<fmt:message code="workflow.th.liushui"/>',
            name:'runId',
            selectFun:function (workLevel,obj) {
                if(obj.state == '已结束'){
                    var imgstr = '<img class="headli1_2_icon" src="../../img/workflow/work/waitwork.png" alt="" style="margin-top: 0">';

                }else{
                    var imgstr = '<img class="headli1_2_icon" src="../../img/workflow/work/endwork.png" alt="" style="margin-top: 0">';
                }
                return imgstr+'&nbsp;'+obj.runId+'<input type="hidden" class="hide" isHidden="'+ obj.isHidden +'" name="'+ obj.runId +'"/>';
            }
        },
        {
            width:width9,
            title:'',
            name:'',
            selectFun:function (workLevel,obj) {
                if(obj.havaSon !=undefined){
                    if(obj.havaSon == 0&&obj.isHidden == 0){
                        return '<img src="../../img/mywork/addlogo.png" style="margin-right: 3px;margin-bottom: 1px;cursor: pointer" title="点击展开" runId="'+ obj.runId +'" onclick="openthis($(this))">';
                    }else{
                        return '';
                    }
                }else{
                    return '';
                }
            }
        },
        {
            width:width2,
            title:'标题',
            name:'workLevel1',
            selectFun:function (workLevel,obj) {
                var workLeverl = getWorkLevle(obj.flowRun.workLevel);
                if(obj.state == '执行中'){
                    var color = "red";
                }else{
                    var color = "green";
                }
                if(obj.workLevel == 0){
                    var fontcolor = 'green';
                }else{
                    var fontcolor = 'red';
                }
                if(obj.flowProcess == undefined){
                    var prcsid = '';
                }else{
                    var prcsid = obj.flowProcess.prcsId;
                }
                if(obj.flowType == undefined){
                    var flowName = '';
                }else{
                    var flowName = obj.flowType.flowName;
                }
                //return '<a class="wenhao wenhao1" style="cursor: pointer;" href="javascript:void(0);" onclick ="js_method($(this))" title="'+obj.runName.split(' ')[0]+'" runId='+obj.runId+' flowId='+obj.flowId+' prcsId='+prcsid+' flowstep='+obj.prcsId+'><span class="font-green" style="color:'+ fontcolor +'">【'+workLeverl+'】</span>'+obj.runName+'</a><br><span style="color: #8e8e8e;font-size: 10pt;">&nbsp;&nbsp;流程名称：'+ flowName +'</span><br>';
                return '<a class="wenhao wenhao1" style="cursor: pointer;" href="javascript:void(0);"  title="'+obj.runName.split(' ')[0]+'" runId='+obj.runId+' flowId='+obj.flowId+' prcsId='+prcsid+' flowstep='+obj.prcsId+'><span class="font-green" style="color:'+ fontcolor +'"></span>'+obj.runName+'</a>';
            }
        },
        {
            width:width10,
            title:'流程名称',
            name:'workLevel2',
            selectFun:function (workLevel,obj) {
                var workLeverl = getWorkLevle(obj.flowRun.workLevel);
                if(obj.state == '执行中'){
                    var color = "red";
                }else{
                    var color = "green";
                }
                if(obj.workLevel == 0){
                    var fontcolor = 'green';
                }else{
                    var fontcolor = 'red';
                }
                if(obj.flowProcess == undefined){
                    var prcsid = '';
                }else{
                    var prcsid = obj.flowProcess.prcsId;
                }
                if(obj.flowType == undefined){
                    var flowName = '';
                }else{
                    var flowName = obj.flowType.flowName;
                }
                //return '<a class="wenhao wenhao1" style="cursor: pointer;" href="javascript:void(0);" onclick ="js_method($(this))" title="'+obj.runName.split(' ')[0]+'" runId='+obj.runId+' flowId='+obj.flowId+' prcsId='+prcsid+' flowstep='+obj.prcsId+'><span class="font-green" style="color:'+ fontcolor +'">【'+workLeverl+'】</span>'+obj.runName+'</a><br><span style="color: #8e8e8e;font-size: 10pt;">&nbsp;&nbsp;流程名称：'+ flowName +'</span><br>';
                return '<span style="color: black;font-size: 10pt;">'+ flowName +'</span><br>';
            }
        },
        {
            width:width7,
            title:'<fmt:message code="attend.th.CurrentStep"/>',
            name:'arriveTime',
            selectFun:function (arriveTime,obj) {
                var zhiWei="";
                if(obj.bz==undefined){
                    zhiWei="null";
                }else{
                    zhiWei=obj.bz;
                }

                console.log(obj)
                if(obj.state == '已结束'){
                    return '<span style="color:red"><fmt:message code="meet.th.IsOver" /></span>'
                }else{
                    if(obj.state2 == 1){

                        var index2=zhiWei.indexOf(":");

                        if(index2!=-1){
                            zhiWei=zhiWei.substr(index2+1)
                        }

                        /*return '<a class="wenhao" style="cursor: pointer;color:green" onclick="bzlct($(this))" runid="'+ obj.flowRun.runId +'" flowid="'+ obj.flowRun.flowId +'">'+zhiWei+'<br><fmt:message code="adding.th.Concurrent" /></a>';*/
                        return '<a class="wenhao" style="cursor: pointer;color:green" onclick="bzlct($(this))" runid="'+ obj.flowRun.runId +'" flowid="'+ obj.flowRun.flowId +'">'+zhiWei+'<br>会签</a>';
                    }else{
                        if(obj.currentPeople == undefined){
                            obj.currentPeople = '';
                        }

                        var index1=zhiWei.indexOf(":");
                        if(index1!=-1){
                            zhiWei=zhiWei.substr(index1+1)
                        }

                        return '<a class="wenhao" style="cursor: pointer;white-space: break-spaces;color:green" onclick="bzlct($(this))" runid="'+ obj.flowRun.runId +'" flowid="'+ obj.flowRun.flowId +'">'+ zhiWei +'<br>'+ obj.currentPeople +'</a>';
                    }
                }
            }
        },{
            width:width11,
            title: '发起部门',
            name: 'department',
            selectFun: function (department, obj) {
                var flowRun=obj.flowRun.beginDept;
                var deptName="false";
                if(allDept==""){
                    getAllDept();
                }
                for (var i=0;i<allDept.length;i++){
                    if(flowRun==allDept[i].deptId){
                        deptName=allDept[i].deptName;
                    }
                }
                return '<span>'+deptName+'</span>';
            }
        },
        {
            width:width3,
            title:'<fmt:message code="workflow.th.Initiator"/>',
            name:'userName',
            selectFun:function (userName,obj) {
                return obj.flowRun.userName;
            }
        },
        {
            width:width5,
            title:'<fmt:message code="workflow.th.Settlingtime"/>',
            name:'prcsTime',
            selectFun:function (prcsTime,obj) {
                var thiss = '';
                if(prcsTime == ""){
                    thiss = '未接收';
                }else{
                    thiss = '接收于:' + prcsTime;
                }
                var thiss2 = '';
                if(obj.deliverTime == ""){
                    thiss2 = '未办结';
                }else{
                    thiss2 =  obj.deliverTime;
                }
                return '<div title="'+thiss2+'">'+thiss2+'</div>';
            }
        },


        {
            width:width8,
            title:'<fmt:message code="menuSSetting.th.menuSetting"/>',
        }
    ],function (me) {
        var flowId = $.GetRequest().flowId;
        if(flowId){
            me.data.flowId = flowId;
            $('.nameBox').css('visibility','hidden');
            $('.index_head li').hide().eq(0).show();
            $('.btn-success').hide();
        }
        me.data.pageSize = 10;

        me.init('../../workflow/work/selectEndWord',[{
            name:'查看',fn:function(obj){
                return "<span style='display: inline-block;width:48px;height:24px;background: #2b7edf;color:#fff;line-height:24px;border-radius:3px;text-align: center'><img src='/img/workflow/work/add_work/seeDetail.png ' style='vertical-align:middle;margin-top: -2px;'/>查</span>";
            }
        },{
            name:'<fmt:message code="roleAuthorization.th.TakeBack" />',fn:function(obj){
                if(obj.prcsFlag=="4"){

                }else {
                    return "<span class='hui_tubiao ' style='display: inline-block;width:48px;height:24px;background: #ef4747;color:#fff;line-height:24px;border-radius:3px;text-align: center'><img src='/img/workflow/work/add_work/shou.png ' style='vertical-align:middle;margin-top: -2px;'/>回</span>";
                }
            }
        },
            {
                name:'传阅',fn:function(obj){
                    if(obj.chuan==1){
                        return "<span style='display: inline-block;width:48px;height:24px;background: #2b7edf;color:#fff;line-height:24px;border-radius:3px;text-align: center'><img src='/img/workflow/work/add_work/seeDetail.png ' style='vertical-align:middle;margin-top: -2px;'/>传</span>";
                    }else{
                        return ''
                    }
                }
            }
        ],function(){
            var indexPage = layer.load(1);
            var length = $('#pageTbody .hide').length;
            for(var i=0;i<length;i++){
                var ishidden = $('#pageTbody .hide').eq(i).attr('ishidden');
                if(ishidden == 1){
                    $('#pageTbody .hide').eq(i).parents('tr').hide();
                }else{
                    $('#pageTbody .hide').eq(i).parents('tr').addClass('tableopen');
                }
            }
            $('.tableopen').eq(0).css({'background-color': '#F6F7F9'}).attr('indexNum',0);
            $('.tableopen').eq(1).css({'background-color': '#FFFFFF'}).attr('indexNum',1);
            $('.tableopen').eq(2).css({'background-color': '#F6F7F9'}).attr('indexNum',2);
            $('.tableopen').eq(3).css({'background-color': '#FFFFFF'}).attr('indexNum',3);
            $('.tableopen').eq(4).css({'background-color': '#F6F7F9'}).attr('indexNum',4);
            layer.close(indexPage)
        });
    })

    $(document).on('click','.tr_click',function () {
        var obj=pageObj.arrs[$(this).attr('data-i')];
        $.ajax({
            url: '/workapp/work/findRelationFuncByFlowFromId?flowFormId='+obj.flowType.formId,
            type: 'post',
            dataType: 'json',
            success: function (res) {
                if(res.code== 0){
                    if(obj.sortMainType=='BUDGETTYPE'){
                        window.open('/workflow/work/workformAppPreView?flowId='+obj.flowRun.flowId+'&prcsId='+obj.flowPrcs+'&flowStep='+obj.prcsId+'&tableName=budget&runId='+obj.runId,'', 'height=700, width=1100, top=55,left=400, toolbar=no, menubar=no, scrollbars=yes , resizable=no,location=no, status=no');
                    }else{
                        window.open('/workflow/work/workformAppPreView?flowId='+obj.flowRun.flowId+'&prcsId='+obj.flowPrcs+'&flowStep='+obj.prcsId+'&tableName=budget&runId='+obj.runId,'', 'height=700, width=1100, top=55,left=400, toolbar=no, menubar=no, scrollbars=yes , resizable=no,location=no, status=no');
                    }
                }else{
                    if(obj.sortMainType=='BUDGETTYPE'){
                        window.open('/workflow/work/workformPreView?flowId='+obj.flowRun.flowId+'&prcsId='+obj.flowPrcs+'&flowStep='+obj.prcsId+'&tableName=budget&runId='+obj.runId,'', 'height=700, width=1100, top=55,left=400, toolbar=no, menubar=no, scrollbars=yes , resizable=no,location=no, status=no');
                    }else{
                        window.open('/workflow/work/workformPreView?flowId='+obj.flowRun.flowId+'&prcsId='+obj.flowPrcs+'&flowStep='+obj.prcsId+'&tableName=budget&runId='+obj.runId,'', 'height=700, width=1100, top=55,left=400, toolbar=no, menubar=no, scrollbars=yes , resizable=no,location=no, status=no');
                    
                    	 
                    }
                }
            }
        });
    })

    $(document).on('click','.editAndDelete1',function (ev) {
        ev.stopPropagation()

        var obj=pageObj.arrs[$(this).attr('data-i')]
		//==========================================nc收回请求
        if(obj.flowPrcs==1){
		var flg=true;
        $.ajax({
            async: false,
            type: "post",
            url: "../../WorkFlowRecallTrigger/api/recall",
            dataType: 'JSON',
            data: {
                runId:obj.runId,
                tabId:obj.flowId
            },
            success: function (obj) {
                if (!obj.flag) {
                    if(null==obj.msg){
                        layer.alert("NC推送过程空指针异常", {
                            anim: 1
							,closeBtn: 0
                            , btn: ['确认']
                            , icon: 5
                            , yes: function () {
                                layer.closeAll('dialog')
                            }

                        });
                    }else{
                        layer.alert(obj.msg, {
                            anim: 1
							,closeBtn: 0
                            , btn: ['确认']
                            , icon: 5
                            , yes: function () {
                                layer.closeAll('dialog')
                            }

                        });
                    }
                    flg=false;
                }else{
                    flg=true;
                }
            },
            error: function (obj) {
                layer.alert(obj, {
                    anim: 1
					,closeBtn: 0
                    , btn: ['确认']
                    , icon: 5
                    , yes: function () {

                        layer.closeAll('dialog')
                    }

                });
                flg=false;
            }
        })
        if(!flg){
            return;
        }
		}
		
        $.ajax({
            type: "get",
            url: "/workflow/work/workBack",
            dataType: 'JSON',
            data: {
                prcsId: obj.prcsId,
                runId: obj.runId,
                flowPrcs: obj.flowPrcs,
                userId:obj.userId,
                tabId:obj.id,
                tableName:obj.tableName
            },
            success: function (res) {
                if(res.flag){
                    $.layerMsg({content:'收回成功！',icon:1});
                    location.reload();
                }else{
                    $.layerMsg({content:'收回失败！',icon:1});
                    location.reload();
                }
            }
        });
    })

    //传阅
    $(document).on('click','.editAndDelete2',function (ev) {
        ev.stopPropagation()
        var obj=pageObj.arrs[$(this).attr('data-i')]
        // console.log(obj)
        layer.open({
            type: 1
            ,area :['600px', '250px']
            ,title: '传阅'
            ,content: '<div style="margin-top: 20px;"  >' +
                '<div style="display: flex;margin-left: 45px;margin-top: 45px;" >\n' +
                '    <label  style="width:70px;padding: 9px 0px;">请选择人员:</label>\n' +
                '    <div  >\n' +
                '      <textarea  type="text" name="userIds"  id="userId" user_id="" disabled style="height: 45px;width: 370px;text-indent:1em;border-radius: 4px;"></textarea>\n' +
                '<a href="javascript:;" style="color:#1E9FFF;margin-left:10px" class="userIdAdd">添加</a>\n' +
                ' <a href="javascript:;" style="color:#1E9FFF;margin-left:5px" class="userIdDel">清空</a>\n'+
                ' </div>\n' +
                '  </div>\n' +
                '</div>'
            ,btn: ['确定', '取消']
            ,success: function(layero, index){
                //人员的添加
                $(".userIdAdd").on("click",function(){
                    user_id = 'userId';
                    $.popWindow("/common/selectUser");
                });
                //人员的删除
                $('.userIdDel').click(function () {
                    $('#userId').attr("dataid","");
                    $('#userId').attr("user_id","");
                    $('#userId').val("");
                });
            }
            ,yes: function(index, layero){
                var flowId=obj.flowRun.flowId
                var prcsId=obj.flowPrcs
                var flowStep=obj.prcsId
                var runId=obj.runId
                var runName=obj.runName
                if(flowId==undefined){
                    flowId=''
                }
                if(prcsId==undefined){
                    prcsId=''
                }
                if(flowStep==undefined){
                    flowStep=''
                }
                if(runId==undefined){
                    runId=''
                }
                if(runName==undefined){
                    runName=''
                }
                $.ajax({
                    url:'/workflow/work/Circulate',
                    type: "post",
                    dataType: "json",
                    data:{
                        viewUser:$('#userId').attr('user_id'),
                        flowId:flowId,
                        prcsId:prcsId,
                        flowStep:flowStep,
                        runId: runId,
                        runName:runName
                    },
                    success:function (res) {
                        if(res.flag){
                            layer.msg('传阅成功！',{icon:1, time: 2000}, function(){
                                layer.close(index)
                            });
                        }
                    }
                })
            }
        });
    })

    $('#bjgz_search').click(function () {
        if($('[name="flowName"]').val()==""){
            $('[name="flowName"]').attr('dataType',null)
        }
        pageObj.data.myworkconditions=$("#flow_search_value_bj").val();
        pageObj.data.flowId=$('[name="flowName"]').attr('dataType');
        pageObj.data.page = 1;
        var url,type;
        pageObj.init(url,type,function(){
            var indexPage = layer.load(1);
            var length = $('#pageTbody .hide').length;
            for(var i=0;i<length;i++){
                var ishidden = $('#pageTbody .hide').eq(i).attr('ishidden');
                if(ishidden == 1){
                    $('#pageTbody .hide').eq(i).parents('tr').hide();
                }
            }
            layer.close(indexPage)
        });
    })

    $(document).click(function(){
        $('.sel').hide()
    })

    $('#list').click(function(e){
        e.stopPropagation()
        if( $('.sel').css('display')!='none'){
            $('.sel').hide()
        }else{
            $('.sel').show()
        }

    })
    $('[name="flowName"]').keyup(function(){
        $('.sel').show()
        var val=$(this).val()
        $('.sel li').each(function(i,v){
//            console.log(v.innerHTML)
            if(v.innerHTML.indexOf(val)>-1){
                $(v).show();
                $(v).parent().show()
            }else{
                $(v).hide();
            }
        })

    })

    $('.sel').on('click','li',function(e){
        e.stopPropagation()
        if($(this).attr('value')){
            $('[name="flowName"]').val($(this).html())
            $('[name="flowName"]').attr('dataType',$(this).attr('value'))
            $('.sel').hide()
        }else{
            $('.sel').show()
        }
    })

    function buildNode(len,data){
        var prefix = 10;
        for(var i=0;i<len;i++){
            prefix += 10;
        }

        $.each(data,function(i,item){
            if(0 < item.childs.length){
                $('.sel').append("<li style='padding-left:"+(prefix)+"px;font-weight:normal;font-size:12px;' id="+item.sortId +">" + item.sortName + "<li>");
                $.each(item.flowTypeModels,function(j,v){
                    $('.sel').append("<li style='padding-left:"+(prefix+10)+"px;cursor:normal' class='canchoose' value="+v.flowId +">" +  v.flowName + "<li>");
                })
                buildNode(len+1,item.childs);
            }else{
                $('.sel').append("<li style='padding-left:"+(prefix)+"px;font-weight:normal;font-size:12px;' id="+item.sortId +">" + item.sortName + "<li>");
                $.each(item.flowTypeModels,function(j,v){
                    $('.sel').append("<li style='padding-left:"+(prefix+10)+"px;cursor:pointer' class='canchoose' value="+v.flowId +">" +  v.flowName + "<li>");
                })
            }
        });
    }
    $(function(){
        $.ajax({
            url:"/flow/selOneToAllType",
            type:'post',
            dataType:'json',
            success:function(res){
                var data=res.datas;
//                console.log(data)
                var str='<option value=""><fmt:message code="hr.th.PleaseSelect"/></option>';
                if(res.flag){
                    $.each(data,function(i,item){
                        $('.sel').append("<li class='ones' style='font-weight:normal;font-size:12px;' id="+item.sortId +"><img src='../../img/data_points.png' style='margin-right: 5px;    margin-top: 9px;width:6px;height:6px' alt=''>" + item.sortName + "<li>");
                        $.each(item.flowTypeModels,function(j,v){
                            $('.sel').append("<li style='padding-left:10px;cursor:pointer' class='canchoose' value="+v.flowId +">" +v.flowName + "<li>");
//                                $('[name="dispatchType"]').append("<option value="+v.flowId +">" + + "</option>");
                        })
                        buildNode(1,item.childs);
                    });
                }
            }
        })
    })
    $(function () {

    })
</script>

</body>
</html>
